﻿using System;
using System.Collections;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace AesEncrypt
{
    public partial class Form3 : Form
    {
        public Form3()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            AesEncryptExtension aes = new AesEncryptExtension();
            byte[] aesIV = Convert.FromBase64String(textBox3.Text);
            byte[] aesKey = Convert.FromBase64String(textBox4.Text);

            textBox1.Text = aes.Decrypt(textBox2.Text, aesKey, aesIV);
        }
    }
}
